package org.spring.springboot.service.impl;

import java.util.List;

import org.spring.springboot.dao.EquipmentDao;
import org.spring.springboot.domain.Equipment;
import org.spring.springboot.service.EquipmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 设备信息业务逻辑实现类
 */
@Service
public class EquipmentServiceImpl implements EquipmentService {

    @Autowired
    private EquipmentDao equipmentDao;

    public Equipment findEquipmentById(int id) {
        return equipmentDao.findById(id);
    }

	@Override
	public Long saveEquipment(Equipment equipment) {
		// TODO Auto-generated method stub
		return equipmentDao.saveEquipment(equipment);
	}

	@Override
	public void updateEquipment(Equipment equipment) {
		// TODO Auto-generated method stub
		equipmentDao.updateEquipment(equipment);
	}


	@Override
	public void deleteEquipmentById(int id) {
		// TODO Auto-generated method stub
		equipmentDao.deleteEquipmentById(id);
	}

	@Override
	public List<Equipment> findAllEquipment() {
		// TODO Auto-generated method stub
		return equipmentDao.findAllEquipment();
	}

}
